package models

import "tuowei.com/common/models"

type SysColleges struct {
	models.Model
	CollegesName    string        `json:"colleges_name" gorm:"type:varchar(50);not null;comment:院校名称"`
	Province        int           `json:"province" gorm:"type:int(10);comment:所属大区ID"`
	ProvinceText    string        `json:"province_text" gorm:"type:varchar(20);comment:所属大区名称"`
	City            int           `json:"city,omitempty" gorm:"type:int(10);comment:所属城市ID"`
	CityText        string        `json:"city_text" gorm:"type:int(10);comment:所属城市名称"`
	Area            int           `json:"area,omitempty" gorm:"type:int(10);comment:所属地区ID"`
	AreaText        string        `json:"area_text" gorm:"type:varchar(50);comment:所属地区名称"`
	DeptId          int           `json:"dept_id,omitempty" gorm:"type:int(5);comment:所属教学点ID"`
	DeptIdText      string        `json:"dept_id_text" gorm:"type:varchar(50);comment:所属教学点名称"`
	TeachingPointId int           `json:"teaching_point_id" gorm:"type:int(10);comment:教学点ID"`
	TeachingPoint   TeachingPoint `json:"teaching_point" gorm:"foreignKey:teaching_point_id"`
	Dept            *CollegesDept `json:"dept"`
	models.ControlBy
	models.ModelTime
}

func (SysColleges) TableName() string {
	return "sys_colleges"
}
